const mysql=require('mysql');
const mysqlContext=(sql, arr, callback)=>{
    const mcc= mysql.createConnection({
        host:'localhost',
        user:'root',
        password:'143145',
        database:'test'
    })
    mcc.connect()//建立连接
    mcc.query(sql, arr, callback)
    mcc.end()//关闭连接
}
module.exports=mysqlContext//导出mysqlContext
